package com.lxyk.pojo;


import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.Value;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;

import javax.annotation.Resource;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class Animals {
    @Autowired   //@Autowired通过Bytype查找  , @Resource先是按照byname查找,找不到然后是按照bytype查找
    @Qualifier(value = "dog222")
    private Dog dog;
    @Autowired
    private Cat cat;
}
